Integrand size = 25, antiderivative size = 403 \[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=\frac {i b^2 c^2}{2 d^2 (i-c x)}-\frac {i b^2 c^2 \arctan (c x)}{2 d^2}-\frac {b c (a+b \arctan (c x))}{d^2 x}-\frac {b c^2 (a+b \arctan (c x))}{d^2 (i-c x)}-\frac {2 c^2 (a+b \arctan (c x))^2}{d^2}-\frac {(a+b \arctan (c x))^2}{2 d^2 x^2}+\frac {2 i c (a+b \arctan (c x))^2}{d^2 x}-\frac {i c^2 (a+b \arctan (c x))^2}{d^2 (i-c x)}-\frac {6 c^2 (a+b \arctan (c x))^2 \text {arctanh}\left (1-\frac {2}{1+i c x}\right )}{d^2}+\frac {b^2 c^2 \log (x)}{d^2}-\frac {3 c^2 (a+b \arctan (c x))^2 \log \left (\frac {2}{1+i c x}\right )}{d^2}-\frac {b^2 c^2 \log \left (1+c^2 x^2\right )}{2 d^2}-\frac {4 i b c^2 (a+b \arctan (c x)) \log \left (2-\frac {2}{1-i c x}\right )}{d^2}-\frac {2 b^2 c^2 \operatorname {PolyLog}\left (2,-1+\frac {2}{1-i c x}\right )}{d^2}-\frac {3 i b c^2 (a+b \arctan (c x)) \operatorname {PolyLog}\left (2,-1+\frac {2}{1+i c x}\right )}{d^2}-\frac {3 b^2 c^2 \operatorname {PolyLog}\left (3,-1+\frac {2}{1+i c x}\right )}{2 d^2} \]
-I*c^2*(a+b*arctan(c*x))^2/d^2/(I-c*x)+1/2*I*b^2*c^2/d^2/(I-c*x)-b*c*(a+b* arctan(c*x))/d^2/x-b*c^2*(a+b*arctan(c*x))/d^2/(I-c*x)-2*c^2*(a+b*arctan(c *x))^2/d^2-1/2*(a+b*arctan(c*x))^2/d^2/x^2+2*I*c*(a+b*arctan(c*x))^2/d^2/x -1/2*I*b^2*c^2*arctan(c*x)/d^2+6*c^2*(a+b*arctan(c*x))^2*arctanh(-1+2/(1+I *c*x))/d^2+b^2*c^2*ln(x)/d^2-3*c^2*(a+b*arctan(c*x))^2*ln(2/(1+I*c*x))/d^2 -1/2*b^2*c^2*ln(c^2*x^2+1)/d^2-4*I*b*c^2*(a+b*arctan(c*x))*ln(2-2/(1-I*c*x ))/d^2-2*b^2*c^2*polylog(2,-1+2/(1-I*c*x))/d^2-3*I*b*c^2*(a+b*arctan(c*x)) *polylog(2,-1+2/(1+I*c*x))/d^2-3/2*b^2*c^2*polylog(3,-1+2/(1+I*c*x))/d^2
Time = 2.59 (sec) , antiderivative size = 489, normalized size of antiderivative = 1.21 \[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=\frac {-\frac {4 a^2}{x^2}+\frac {16 i a^2 c}{x}+\frac {8 i a^2 c^2}{-i+c x}+24 i a^2 c^2 \arctan (c x)-24 a^2 c^2 \log (x)+12 a^2 c^2 \log \left (1+c^2 x^2\right )-b^2 c^2 \left (-i \pi ^3+\frac {8 \arctan (c x)}{c x}+20 \arctan (c x)^2+\frac {4 \arctan (c x)^2}{c^2 x^2}-\frac {16 i \arctan (c x)^2}{c x}-2 \cos (2 \arctan (c x))-4 i \arctan (c x) \cos (2 \arctan (c x))+4 \arctan (c x)^2 \cos (2 \arctan (c x))+24 \arctan (c x)^2 \log \left (1-e^{-2 i \arctan (c x)}\right )+32 i \arctan (c x) \log \left (1-e^{2 i \arctan (c x)}\right )-8 \log (c x)+4 \log \left (1+c^2 x^2\right )+24 i \arctan (c x) \operatorname {PolyLog}\left (2,e^{-2 i \arctan (c x)}\right )+16 \operatorname {PolyLog}\left (2,e^{2 i \arctan (c x)}\right )+12 \operatorname {PolyLog}\left (3,e^{-2 i \arctan (c x)}\right )+2 i \sin (2 \arctan (c x))-4 \arctan (c x) \sin (2 \arctan (c x))-4 i \arctan (c x)^2 \sin (2 \arctan (c x))\right )+4 i a b c^2 \left (\frac {2 i}{c x}+12 \arctan (c x)^2+\cos (2 \arctan (c x))-8 \log (c x)+4 \log \left (1+c^2 x^2\right )+6 \operatorname {PolyLog}\left (2,e^{2 i \arctan (c x)}\right )-i \sin (2 \arctan (c x))+2 \arctan (c x) \left (i+\frac {i}{c^2 x^2}+\frac {4}{c x}+i \cos (2 \arctan (c x))+6 i \log \left (1-e^{2 i \arctan (c x)}\right )+\sin (2 \arctan (c x))\right )\right )}{8 d^2} \]
((-4*a^2)/x^2 + ((16*I)*a^2*c)/x + ((8*I)*a^2*c^2)/(-I + c*x) + (24*I)*a^2 *c^2*ArcTan[c*x] - 24*a^2*c^2*Log[x] + 12*a^2*c^2*Log[1 + c^2*x^2] - b^2*c ^2*((-I)*Pi^3 + (8*ArcTan[c*x])/(c*x) + 20*ArcTan[c*x]^2 + (4*ArcTan[c*x]^ 2)/(c^2*x^2) - ((16*I)*ArcTan[c*x]^2)/(c*x) - 2*Cos[2*ArcTan[c*x]] - (4*I) *ArcTan[c*x]*Cos[2*ArcTan[c*x]] + 4*ArcTan[c*x]^2*Cos[2*ArcTan[c*x]] + 24* ArcTan[c*x]^2*Log[1 - E^((-2*I)*ArcTan[c*x])] + (32*I)*ArcTan[c*x]*Log[1 - E^((2*I)*ArcTan[c*x])] - 8*Log[c*x] + 4*Log[1 + c^2*x^2] + (24*I)*ArcTan[ c*x]*PolyLog[2, E^((-2*I)*ArcTan[c*x])] + 16*PolyLog[2, E^((2*I)*ArcTan[c* x])] + 12*PolyLog[3, E^((-2*I)*ArcTan[c*x])] + (2*I)*Sin[2*ArcTan[c*x]] - 4*ArcTan[c*x]*Sin[2*ArcTan[c*x]] - (4*I)*ArcTan[c*x]^2*Sin[2*ArcTan[c*x]]) + (4*I)*a*b*c^2*((2*I)/(c*x) + 12*ArcTan[c*x]^2 + Cos[2*ArcTan[c*x]] - 8* Log[c*x] + 4*Log[1 + c^2*x^2] + 6*PolyLog[2, E^((2*I)*ArcTan[c*x])] - I*Si n[2*ArcTan[c*x]] + 2*ArcTan[c*x]*(I + I/(c^2*x^2) + 4/(c*x) + I*Cos[2*ArcT an[c*x]] + (6*I)*Log[1 - E^((2*I)*ArcTan[c*x])] + Sin[2*ArcTan[c*x]])))/(8 *d^2)
Time = 1.12 (sec) , antiderivative size = 403, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.080, Rules used = {5411, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx\) |
\(\Big \downarrow \) 5411 |
\(\displaystyle \int \left (\frac {3 c^3 (a+b \arctan (c x))^2}{d^2 (c x-i)}-\frac {i c^3 (a+b \arctan (c x))^2}{d^2 (c x-i)^2}-\frac {3 c^2 (a+b \arctan (c x))^2}{d^2 x}+\frac {(a+b \arctan (c x))^2}{d^2 x^3}-\frac {2 i c (a+b \arctan (c x))^2}{d^2 x^2}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {6 c^2 \text {arctanh}\left (1-\frac {2}{1+i c x}\right ) (a+b \arctan (c x))^2}{d^2}-\frac {3 i b c^2 \operatorname {PolyLog}\left (2,\frac {2}{i c x+1}-1\right ) (a+b \arctan (c x))}{d^2}-\frac {i c^2 (a+b \arctan (c x))^2}{d^2 (-c x+i)}-\frac {2 c^2 (a+b \arctan (c x))^2}{d^2}-\frac {b c^2 (a+b \arctan (c x))}{d^2 (-c x+i)}-\frac {3 c^2 \log \left (\frac {2}{1+i c x}\right ) (a+b \arctan (c x))^2}{d^2}-\frac {4 i b c^2 \log \left (2-\frac {2}{1-i c x}\right ) (a+b \arctan (c x))}{d^2}-\frac {(a+b \arctan (c x))^2}{2 d^2 x^2}+\frac {2 i c (a+b \arctan (c x))^2}{d^2 x}-\frac {b c (a+b \arctan (c x))}{d^2 x}-\frac {i b^2 c^2 \arctan (c x)}{2 d^2}-\frac {2 b^2 c^2 \operatorname {PolyLog}\left (2,\frac {2}{1-i c x}-1\right )}{d^2}-\frac {3 b^2 c^2 \operatorname {PolyLog}\left (3,\frac {2}{i c x+1}-1\right )}{2 d^2}-\frac {b^2 c^2 \log \left (c^2 x^2+1\right )}{2 d^2}+\frac {i b^2 c^2}{2 d^2 (-c x+i)}+\frac {b^2 c^2 \log (x)}{d^2}\) |
((I/2)*b^2*c^2)/(d^2*(I - c*x)) - ((I/2)*b^2*c^2*ArcTan[c*x])/d^2 - (b*c*( a + b*ArcTan[c*x]))/(d^2*x) - (b*c^2*(a + b*ArcTan[c*x]))/(d^2*(I - c*x)) - (2*c^2*(a + b*ArcTan[c*x])^2)/d^2 - (a + b*ArcTan[c*x])^2/(2*d^2*x^2) + ((2*I)*c*(a + b*ArcTan[c*x])^2)/(d^2*x) - (I*c^2*(a + b*ArcTan[c*x])^2)/(d ^2*(I - c*x)) - (6*c^2*(a + b*ArcTan[c*x])^2*ArcTanh[1 - 2/(1 + I*c*x)])/d ^2 + (b^2*c^2*Log[x])/d^2 - (3*c^2*(a + b*ArcTan[c*x])^2*Log[2/(1 + I*c*x) ])/d^2 - (b^2*c^2*Log[1 + c^2*x^2])/(2*d^2) - ((4*I)*b*c^2*(a + b*ArcTan[c *x])*Log[2 - 2/(1 - I*c*x)])/d^2 - (2*b^2*c^2*PolyLog[2, -1 + 2/(1 - I*c*x )])/d^2 - ((3*I)*b*c^2*(a + b*ArcTan[c*x])*PolyLog[2, -1 + 2/(1 + I*c*x)]) /d^2 - (3*b^2*c^2*PolyLog[3, -1 + 2/(1 + I*c*x)])/(2*d^2)
3.2.10.3.1 Defintions of rubi rules used
Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))^(p_.)*((f_.)*(x_))^(m_.)*((d_) + (e_ .)*(x_))^(q_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*ArcTan[c*x])^p, (f* x)^m*(d + e*x)^q, x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && IGtQ[p, 0] & & IntegerQ[q] && (GtQ[q, 0] || NeQ[a, 0] || IntegerQ[m])
Result contains higher order function than in optimal. Order 9 vs. order 4.
Time = 38.54 (sec) , antiderivative size = 1967, normalized size of antiderivative = 4.88
method | result | size |
derivativedivides | \(\text {Expression too large to display}\) | \(1967\) |
default | \(\text {Expression too large to display}\) | \(1967\) |
parts | \(\text {Expression too large to display}\) | \(1975\) |
c^2*(-1/2*a^2/d^2/c^2/x^2+2*I*a^2/d^2/c/x-3*a^2/d^2*ln(c*x)+I*a^2/d^2/(c*x -I)+3/2*a^2/d^2*ln(c^2*x^2+1)+3*I*a^2/d^2*arctan(c*x)+b^2/d^2*(-1/2/c^2/x^ 2*arctan(c*x)^2-6*polylog(3,(1+I*c*x)/(c^2*x^2+1)^(1/2))+ln(1+(1+I*c*x)/(c ^2*x^2+1)^(1/2))-6*polylog(3,-(1+I*c*x)/(c^2*x^2+1)^(1/2))+ln((1+I*c*x)/(c ^2*x^2+1)^(1/2)-1)-2*arctan(c*x)^2+3*arctan(c*x)^2*ln((1+I*c*x)^2/(c^2*x^2 +1)-1)-3*arctan(c*x)^2*ln(c*x)-3*arctan(c*x)^2*ln(1-(1+I*c*x)/(c^2*x^2+1)^ (1/2))-3*arctan(c*x)^2*ln(1+(1+I*c*x)/(c^2*x^2+1)^(1/2))-4*dilog(1+(1+I*c* x)/(c^2*x^2+1)^(1/2))+4*dilog((1+I*c*x)/(c^2*x^2+1)^(1/2))-1/2*arctan(c*x) *(I*c*x-(c^2*x^2+1)^(1/2)+1)/c/x-1/2*arctan(c*x)*(I*c*x+(c^2*x^2+1)^(1/2)+ 1)/c/x-3/2*I*Pi*csgn(I/(1+(1+I*c*x)^2/(c^2*x^2+1)))*csgn(I*((1+I*c*x)^2/(c ^2*x^2+1)-1))*csgn(I*((1+I*c*x)^2/(c^2*x^2+1)-1)/(1+(1+I*c*x)^2/(c^2*x^2+1 )))*arctan(c*x)^2+6*I*arctan(c*x)*polylog(2,(1+I*c*x)/(c^2*x^2+1)^(1/2))+6 *I*arctan(c*x)*polylog(2,-(1+I*c*x)/(c^2*x^2+1)^(1/2))-3/2*I*Pi*csgn(I*((1 +I*c*x)^2/(c^2*x^2+1)-1)/(1+(1+I*c*x)^2/(c^2*x^2+1)))^3*arctan(c*x)^2-3/2* I*Pi*csgn(((1+I*c*x)^2/(c^2*x^2+1)-1)/(1+(1+I*c*x)^2/(c^2*x^2+1)))^3*arcta n(c*x)^2+3/2*I*Pi*csgn(((1+I*c*x)^2/(c^2*x^2+1)-1)/(1+(1+I*c*x)^2/(c^2*x^2 +1)))^2*arctan(c*x)^2+3/2*I*Pi*csgn(I/(1+(1+I*c*x)^2/(c^2*x^2+1)))*csgn(I* ((1+I*c*x)^2/(c^2*x^2+1)-1)/(1+(1+I*c*x)^2/(c^2*x^2+1)))^2*arctan(c*x)^2+3 /2*I*Pi*csgn(I*((1+I*c*x)^2/(c^2*x^2+1)-1))*csgn(I*((1+I*c*x)^2/(c^2*x^2+1 )-1)/(1+(1+I*c*x)^2/(c^2*x^2+1)))^2*arctan(c*x)^2+3/2*I*Pi*csgn(I*((1+I...
\[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=\int { \frac {{\left (b \arctan \left (c x\right ) + a\right )}^{2}}{{\left (i \, c d x + d\right )}^{2} x^{3}} \,d x } \]
1/8*(6*(b^2*c^3*x^3 - I*b^2*c^2*x^2)*log(2*c*x/(c*x - I))*log(-(c*x + I)/( c*x - I))^2 + 12*(b^2*c^3*x^3 - I*b^2*c^2*x^2)*dilog(-2*c*x/(c*x - I) + 1) *log(-(c*x + I)/(c*x - I)) + (-6*I*b^2*c^2*x^2 - 3*b^2*c*x - I*b^2)*log(-( c*x + I)/(c*x - I))^2 + 8*(c*d^2*x^3 - I*d^2*x^2)*integral(-1/2*(2*a^2*c*x + 2*I*a^2 - (6*b^2*c^3*x^3 - 3*I*b^2*c^2*x^2 + (-2*I*a*b + b^2)*c*x + 2*a *b)*log(-(c*x + I)/(c*x - I)))/(c^3*d^2*x^6 - I*c^2*d^2*x^5 + c*d^2*x^4 - I*d^2*x^3), x) - 12*(b^2*c^3*x^3 - I*b^2*c^2*x^2)*polylog(3, -(c*x + I)/(c *x - I)))/(c*d^2*x^3 - I*d^2*x^2)
\[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=- \frac {\int \frac {a^{2}}{c^{2} x^{5} - 2 i c x^{4} - x^{3}}\, dx + \int \frac {b^{2} \operatorname {atan}^{2}{\left (c x \right )}}{c^{2} x^{5} - 2 i c x^{4} - x^{3}}\, dx + \int \frac {2 a b \operatorname {atan}{\left (c x \right )}}{c^{2} x^{5} - 2 i c x^{4} - x^{3}}\, dx}{d^{2}} \]
-(Integral(a**2/(c**2*x**5 - 2*I*c*x**4 - x**3), x) + Integral(b**2*atan(c *x)**2/(c**2*x**5 - 2*I*c*x**4 - x**3), x) + Integral(2*a*b*atan(c*x)/(c** 2*x**5 - 2*I*c*x**4 - x**3), x))/d**2
Exception generated. \[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=\text {Exception raised: RuntimeError} \]
\[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=\int { \frac {{\left (b \arctan \left (c x\right ) + a\right )}^{2}}{{\left (i \, c d x + d\right )}^{2} x^{3}} \,d x } \]
Timed out. \[ \int \frac {(a+b \arctan (c x))^2}{x^3 (d+i c d x)^2} \, dx=\int \frac {{\left (a+b\,\mathrm {atan}\left (c\,x\right )\right )}^2}{x^3\,{\left (d+c\,d\,x\,1{}\mathrm {i}\right )}^2} \,d x \]